*{
    margin: 0;
    padding: 0;
}
body{
    display: flex;
    height: 100vh;
    justify-content: center;
    align-items: center;
    background: radial-gradient(circle at top center,#718497,#29323c);

}
.container{
    display: flex;
    width: 90vw;
    max-width: 900px;
    height: 400px;
    overflow: hidden;
}
.item{
    position: relative;
    background-size: cover;
    background-position: center;
    border-radius: 30px;
    width: 60px;
    cursor: pointer;
    margin: 10px;
    transition: 0.5s;
    overflow: hidden;
}
.item .shadow {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 100px;
    transition: 0.5s;
}
.item .content {
    position: absolute;
    display: flex;
    bottom: 0;
    left: 10px;
    right: 0;
    height: 40px;
    transition: 0.5s;
}
.item .content .icon {
    min-width: 40px;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: #ffffff;
    text-align: center;
    line-height: 40px;
    font-size: 18px;
}
.item:nth-child(1) .fa {
    color: #fc6e51;
}
.item:nth-child(2) .fa {
    color: #ffce54;
}
.item:nth-child(3) .fa {
    color: #2ecc71;
}
.item:nth-child(4) .fa {
    color: #5d9cec;
}
.item:nth-child(5) .fa {
    color: #ac92ec;
}
.item .content .text{
    display: flex;
    flex-direction: column;
    color: #ffffff;
    margin-left: 10px;
    /*文字超出部分会上下以块区域居中*/
    justify-content: center;
    width: 100%;
}
.item .content .text div {
    width: calc(100% - 70px);
    text-overflow: ellipsis;
    /*overflow: hidden;*/
    white-space: nowrap;
    opacity: 0;
    transition: opacity 0.5s;
}
.item .content .text .tit {
    font-weight: bold;
    font-size: 18px;
}
.item .content .text .sub {
    transition-delay: 0.1s;
}
.item.active{
    flex: 1;
    margin: 0;
    border-radius: 40px;
}
.item.active .shadow {
    background: linear-gradient(to top,rgba(0,0,0,0.35) 65%, transparent);
}
.item.active .content {
    bottom: 20px;
    left: 20px;
}
.item.active .content .text div{
    opacity: 1;
}